package exception;

/**
 * 异常抛出
 */
public class ThrowDemo {
    public static void main(String[] args) throws IllegalAgeException {
        Student zs=new Student();
        zs.setAge(22);
        System.out.println("他的年龄为："+zs.getAge()+"岁");

    }
}
